interface from the bridge when going offline -- the comment stating that
interfaces are auto-removed does not seem to be true, at least some of the
time. Log failure of brctl delif and ifconfig down only at debug level, as
this script may be called more than once, depending upon the hotplug
configuration.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
;;
offline)
- # vifs are auto-removed from bridge.
- ifconfig "$vif" down || log err "ifconfig $vif down failed"
+ brctl delif "$bridge" "$vif" ||
+ log debug "brctl delif $bridge $vif failed"
+ ifconfig "$vif" down || log debug "ifconfig $vif down failed"
;;
esac
handle_iptable
-log debug "Successful vif-bridge operation for $vif, bridge $bridge."
-success
+log debug "Successful vif-bridge $command for $vif, bridge $bridge."
+if [ "$command" == "online" ]
+then
+ success
+fi